<?php
/**
 * 
 * Digitalus2 CMS
 *
 * @package    	Digitalus\Ui
 * @copyright  	Copyright (c) 2009,  Digitalus Media USA (http://digitalusmedia.net)
 * @license    	New BSD License, library/Dig/License.txt
 * @version 	2.0
 * 
 */
class DigUi_TemplateController extends Zend_Controller_Action 
{
    public function init()
    {
        DigUi_Service_Template::useAdminTemplate();
    }
    
    public function indexAction()
    {

    }
    
    public function setAction()
    {
        $template = $this->getRequest()->getParam('template');
        $layout = $this->getRequest()->getParam('layout', 'layout');
        // set the layout to the passed template
        $templatePath = '/templates/' . $template;
        $this->_helper->layout->setLayoutPath(APPLICATION_PATH . '/../public_html' . $templatePath)
                              ->setLayout($layout);
    }
}
?>